package com.gongjie.blog.dao.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.gongjie.blog.dao.pojo.Tag;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

/**
 * @author jiegong
 * @create 2021-09-22 16:23
 */
@Mapper
public interface TagMapper extends BaseMapper<Tag> {

    //根据文章id查询标签列表
    List<Tag> findTagsByArticleId(Long articleId);

    //查询最热标签，前limit条
    List<Long> findHotsTagIds(int limit);

    List<Tag> findTagsByIds(List<Long> tagIds);
}
